package com.mbc.web.common.client.controller;

import com.google.gwt.user.client.rpc.RemoteService;
import com.google.gwt.user.client.rpc.RemoteServiceRelativePath;
import com.mbc.common.entities.Role;
import com.mbc.common.entities.User;
import com.mbc.common.param.CriteriaParams;
import com.mbc.web.common.shared.dto.BranchChangeLogDataListDTO;
import com.mbc.web.common.shared.dto.LevelAppItemListDTO;
import com.mbc.web.common.shared.dto.RoleDataListDTO;
import com.mbc.web.common.shared.dto.RoleListDTO;
import com.mbc.web.common.shared.dto.UserDataListDTO;
import com.mbc.web.common.shared.dto.UserViewLoadDTO;

@RemoteServiceRelativePath("webaccess")
public interface WebAccessController extends RemoteService {
	//User
	int createUser(User user);
	int updateUser(User user);
	int deleteUser(long userID);
	UserDataListDTO getUserList(CriteriaParams cri);
	User getUser(long userId);
	User findUserByLoginId(String loginId);
	UserViewLoadDTO getUserViewLoadData();
	int resetLoginPassword(String oldPassword, String newPassword);
	int changeUserBranch(String loginId, long branchId);
	BranchChangeLogDataListDTO findUserBranchChangeLogs(CriteriaParams cri);
	//End User
	
	//Role
	int createRole(Role role);
	int updateRole(Role role);
	int deleteRole(long roleId);
	Role findRole(long roleId);
	RoleListDTO getAllRole();
	RoleDataListDTO getRoleList(CriteriaParams cri);
	LevelAppItemListDTO getLevelAppItemByRoleId(long roleId);
	//end Role
}